<ion-view view-title="我的预约">
    <ion-nav-buttons side="right">
        <button class="button button-icon ion-android-refresh" ng-click="reloadHistory()">
        </button>
    </ion-nav-buttons>
    <ion-content>
        <ion-refresher pulling-text="下拉刷新数据" on-refresh="reloadHistory(true)">
        </ion-refresher>
        <ion-list>
            <ion-item ng-click="withDrawRegistration(history)" ng-repeat="history in histories" type="item-text-wrap">
                <h2>{{history.date}}</h2>
                <p>{{history.dept}} -- {{history.doctorName}}</p>
                <p><span ng-class="{'balanced':history.canWithdraw}">{{history.status}}</span></p>
            </ion-item>
        </ion-list>
        <div class="card" ng-if="histories.length == 0 ">
            <div class="item item-text-wrap">
                您没有任何预约记录。
            </div>
        </div>
    </ion-content>
</ion-view>
